using System.Collections.Generic;
using System.Reflection;
using GGEditor.API;

namespace GGEditor.Core.Plugins
{
	class PluginBuilder : IPlugin
	{
		public string DirPath { get; set; }

		public PluginBuilder()
		{
			
		}

		private readonly IList<Assembly> assemblies = new List<Assembly>();

		private readonly IList<IPluginExtension> extensions = new List<IPluginExtension>();

		internal void AddAssembly(Assembly assembly)
		{
			assemblies.Add(assembly);
		}

		internal void AddExtension(IPluginExtension extension)
		{
			extensions.Add(extension);
		}

		#region Implementation of IPlugin

		public string Name { get; internal set; }

		public string Description { get; internal set; }

		public string Version { get; internal set; }

		public string Author { get; internal set; }

		public string Copyright { get; internal set; }

		public string Url { get; internal set; }

		public IEnumerable<Assembly> Assemblies
		{
			get { return assemblies; }
		}

		public IEnumerable<IPluginExtension> Extensions
		{
			get { return extensions; }
		}

		#endregion
	}
}